import request from '@/utils/request'
import apis from './'

export function ipList (parameter) {
  return request({
    url: apis.IpList,
    method: 'get',
    params: parameter
  })
}

export function addIp (data) {
  return request({
    url: apis.AddIp,
    method: 'post',
    data: data
  })
}

export function delIp (id) {
  return request({
    url: `${apis.DelIp}?id=${id}`,
    method: 'get'
  })
}

export function getGoodTrademark (parameter) {
  return request({
    url: apis.GoodTrademark,
    method: 'get',
    params: parameter
  })
}

export function changeStatus (ids, data) {
  return request({
    url: `${apis.GetTradeOpts}?ids[]=${ids}`,
    method: 'post',
    data: data
  })
}

export function getTradeOpts () {
  return request({
    url: apis.GetTradeOpts,
    method: 'get'
  })
}
